package com.mlm.mlmapp.adapter.view.adapter;

import android.app.ProgressDialog;
import android.content.Context;
import android.os.Bundle;

import com.mlm.mlmapp.R;

/**
 * Created by stone on 16/3/8.
 */
public class DownloadProgressDialog extends ProgressDialog {
    Context mContext;
    NumberProgressBar pwOne;
    public DownloadProgressDialog(Context context) {
        super(context);
        this.mContext=context;
        this.setCancelable(false);
//        this.setIndeterminate(true);
//        this.setCancelable(true);
//        this.setInverseBackgroundForced(false);
//        this.setCanceledOnTouchOutside(true);
//        this.setTitle("加载中");
    }
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.download_progressbar);
        pwOne = (NumberProgressBar) findViewById(R.id.progress);

    }
    public void setIntProgress(int progress){
        pwOne.setProgress(progress);
    }


    @Override
    public void onBackPressed() {
        super.onBackPressed();
        this.dismiss();
    }
}
